It is not BIOS specific.
Signed-off-by: Keir Fraser <keir@xen.org>
void (*bios_info_setup)(void);
void (*bios_info_finish)(void);
- void (*vm86_setup)(void);
void (*e820_setup)(void);
void (*acpi_build_tables)(void);
cmos_outb(0x35, (uint8_t)( alt_mem >> 8));
}
+/*
+ * Set up an empty TSS area for virtual 8086 mode to use.
+ * The only important thing is that it musn't have any bits set
+ * in the interrupt redirection bitmap, so all zeros will do.
+ */
+static void init_vm86_tss(void)
+{
+ void *tss;
+ struct xen_hvm_param p;
+
+ tss = mem_alloc(128, 128);
+ memset(tss, 0, 128);
+ p.domid = DOMID_SELF;
+ p.index = HVM_PARAM_VM86_TSS;
+ p.value = virt_to_phys(tss);
+ hypercall_hvm_op(HVMOP_set_param, &p);
+ printf("vm86 TSS at %08lx\n", virt_to_phys(tss));
+}
+
static void apic_setup(void)
{
/* Set the IOAPIC ID to the static value used in the MP/ACPI tables. */
hypercall_hvm_op(HVMOP_set_param, &p);
}
- if ( bios->vm86_setup )
- bios->vm86_setup();
+ init_vm86_tss();
cmos_write_memory_size();
#define ROMBIOS_MAXOFFSET 0x0000FFFF
#define ROMBIOS_END (ROMBIOS_BEGIN + ROMBIOS_SIZE)
-/*
- * Set up an empty TSS area for virtual 8086 mode to use.
- * The only important thing is that it musn't have any bits set
- * in the interrupt redirection bitmap, so all zeros will do.
- */
-static void rombios_init_vm86_tss(void)
-{
- void *tss;
- struct xen_hvm_param p;
-
- tss = mem_alloc(128, 128);
- memset(tss, 0, 128);
- p.domid = DOMID_SELF;
- p.index = HVM_PARAM_VM86_TSS;
- p.value = virt_to_phys(tss);
- hypercall_hvm_op(HVMOP_set_param, &p);
- printf("vm86 TSS at %08lx\n", virt_to_phys(tss));
-}
-
static void rombios_setup_e820(void)
{
/*
.bios_info_setup = rombios_setup_bios_info,
.bios_info_finish = NULL,
- .vm86_setup = rombios_init_vm86_tss,
.e820_setup = rombios_setup_e820,
.acpi_build_tables = rombios_acpi_build_tables,
.bios_info_setup = seabios_setup_bios_info,
.bios_info_finish = seabios_finish_bios_info,
- .vm86_setup = NULL,
.e820_setup = seabios_setup_e820,
.acpi_build_tables = seabios_acpi_build_tables,